Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bugfix: functional() throws error for a break statement #130

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

PoorvaGarg
Copy link

@PoorvaGarg PoorvaGarg commented Oct 4, 2024

Fixes #129

functional() failed to handle a break statement inside a loop but outside an if-then-else. The source of this bug was the function dominators(cfg; entry = 1) in src/passes/passes.jl not handling the unreachable blocks of the control flow graph properly. This pull request fixes that and adds relevant tests.

PR Checklist

  • [ YES] Tests are added
  • [ N/A] Documentation, if applicable

@PoorvaGarg PoorvaGarg changed the title Fixes bug for while break Bugfix: functional() throws error for a break statement Oct 4, 2024
@PoorvaGarg PoorvaGarg marked this pull request as ready for review October 4, 2024 21:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

functional() throws error for a break statement
1 participant